Namespace definitions

Global namespace containing types and functions accessible without any namespace prefix.

Global namespace containing types and functions accessible without any namespace prefix.

Types

Link copied to clipboard

A data type that represents large integers with high precision, capable of handling very large numbers. Uses java.math.BigInteger internally.

Link copied to clipboard
type boolean

A simple data type that represents two values: true and false.

Link copied to clipboard

An array of bytes. This type is immutable.

Link copied to clipboard
hidden abstract type collection<T> : iterable<T>
Link copied to clipboard
hidden abstract type comparable
Link copied to clipboard
type decimal

A data type for representing real numbers with high precision. Uses java.math.BigDecimal internally.

Link copied to clipboard
hidden abstract type entity

Common parent type of all entity types. An entity is a data structure that reside in the SQL database.

Link copied to clipboard
hidden abstract type enum
Link copied to clipboard
type gtv

Generic Transfer Value (GTV) is a general-purpose type for sending and decoding any data structure.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
alias GTXValue = gtv

Generic Transfer Value (GTV) is a general-purpose type for sending and decoding any data structure.

Alias
Link copied to clipboard
hidden abstract type immutable
Link copied to clipboard
hidden abstract type immutable_mirror_struct<T> : mirror_struct<T>
Link copied to clipboard
type integer

Represents a 64-bit signed integer

Link copied to clipboard
hidden abstract type iterable<T>
Link copied to clipboard
type json

Wrapper object for a JSON-string.

Link copied to clipboard
type list<T> : collection<T>

Represents a mutable array list.

Link copied to clipboard
type map<K: -immutable, V> : iterable<(K, V)>

Represents a mutable map that preserves entry iteration order.

Link copied to clipboard
hidden type map_entry<K, V>

A parent type for all two-element tuples (with named and unnamed fields). Is used for iterating through maps and constructing maps from iterables

Link copied to clipboard
hidden abstract type mirror_struct<T>
Link copied to clipboard
hidden abstract type mutable_mirror_struct<T> : mirror_struct<T>
Link copied to clipboard
alias name = text

An immutable data type for representing character strings.

Alias
Link copied to clipboard
hidden abstract type null_ext
Link copied to clipboard
hidden abstract type object
Link copied to clipboard
hidden abstract type operation
Link copied to clipboard

An array of bytes. This type is immutable.

Link copied to clipboard

An integer range of values

Link copied to clipboard
type rowid

The primary key of a database record, a 64-bit integer.

Link copied to clipboard
type set<T: -immutable> : collection<T>

Represents a mutable set of elements. The set is a hash-set with an iteration order determined by the order the elements was first added to the set.

Link copied to clipboard
hidden abstract type struct
Link copied to clipboard
type text

An immutable data type for representing character strings.

Link copied to clipboard

Represents a 64-bit signed integer

Alias
Link copied to clipboard
type unit
Link copied to clipboard
hidden type virtual<T>
Link copied to clipboard
hidden abstract type virtual_collection<T> : iterable<T>
Link copied to clipboard
hidden type virtual_list<T, T2> : virtual_collection<T2>
Link copied to clipboard
hidden type virtual_map<K: -immutable, V0, V> : iterable<(K, V)>
Link copied to clipboard

Functions

Link copied to clipboard

Gets the absolute value of a big_integer.

function abs(a: decimal): decimal

Gets the absolute value of a decimal.

function abs(a: integer): integer

Gets the absolute value of a integer.

Link copied to clipboard
(alias) function <T> assert_equals(actual: T, expected: T)

Asserts that two values are equal.

Link copied to clipboard
(alias) function assert_events(expected: (text, gtv)...)

Asserts that the expected events has been emitted during last block

Link copied to clipboard
(alias) function <T> assert_fails(fn: () -> T): rell.test.failure

Asserts that a function fails to evaluate

(alias) function <T> assert_fails(expected_message: text, fn: () -> T): rell.test.failure

Asserts that a function fails with an expected message

Link copied to clipboard
(alias) function assert_false(actual: boolean)

Asserts that the value is false.

Link copied to clipboard
(alias) function <T: -comparable> assert_ge(actual: T, expected: T)

Asserts that the value is greater than or equal to the expected value

Link copied to clipboard
(alias) function <T: -comparable> assert_ge_le(actual: T, expected1: T, expected2: T)

Asserts that the value is greater than or equal to the first value and less than or equal to the second value.

Link copied to clipboard
(alias) function <T: -comparable> assert_ge_lt(actual: T, expected1: T, expected2: T)

Asserts that the value is greater than or equal to the first value and less than the second value.

Link copied to clipboard
(alias) function <T: -comparable> assert_gt(actual: T, expected: T)

Asserts that the value is greater than the expected value

Link copied to clipboard
(alias) function <T: -comparable> assert_gt_le(actual: T, expected1: T, expected2: T)

Asserts that the value is greater than the first value and less than or equal to the second value.

Link copied to clipboard
(alias) function <T: -comparable> assert_gt_lt(actual: T, expected1: T, expected2: T)

Asserts that the value is greater than the first value and less than the second value.

Link copied to clipboard
(alias) function <T: -comparable> assert_le(actual: T, expected: T)

Asserts that the value is less than or equal to the expected value

Link copied to clipboard
(alias) function <T: -comparable> assert_lt(actual: T, expected: T)

Asserts that the value is less than the expected value

Link copied to clipboard
(alias) function <T> assert_not_equals(actual: T, illegal: T)

Asserts that two values are not equal.

Link copied to clipboard
(alias) function <T: -any> assert_not_null(actual: T?)

Asserts that the value is not null.

Link copied to clipboard
(alias) function assert_null(actual: anything)

Asserts that the value is null.

Link copied to clipboard
(alias) function assert_true(actual: boolean)

Asserts that the value is true.

Link copied to clipboard
function <T> empty(arg: T?): boolean

Checks if the value is null or empty.

Link copied to clipboard
(alias) function eth_ecrecover(r: byte_array, s: byte_array, rec_id: integer, data_hash: byte_array): byte_array

Calculates an Ethereum public key from a signature and hash.

Link copied to clipboard
function <T> exists(arg: T?): boolean

Checks if the value is null or empty.

Link copied to clipboard
function is_signer(pubkey: byte_array): boolean
Link copied to clipboard
(alias) function keccak256(input: byte_array): byte_array

Calculates a Keccak256 hash of a byte array and returns a byte array.

Link copied to clipboard
function log(values: anything...)

Prints the given message to the node log with timestamp

Link copied to clipboard

Identifies the larger of two big_integer values.

function max(a: decimal, b: decimal): decimal

Identifies the larger of two decimal values.

function max(a: integer, b: integer): integer

Identifies the larger of two integer values.

Link copied to clipboard

Determines the smaller of two big_integer values.

function min(a: decimal, b: decimal): decimal

Determines the smaller of two decimal values.

function min(a: integer, b: integer): integer

Determines the smaller of two integer values.

Link copied to clipboard
function print(values: anything...)

Prints the given message to the node log

Link copied to clipboard
function <T: -any> require(value: T?, message: text): T

Checks for null values and throws an exception if null.

function require(value: boolean, message: text)

Checks a boolean condition and throws an exception if false.

Link copied to clipboard
function <T: -any> require_not_empty(value: T?, message: text): T

Checks for precence of a value and throws an exception if null.

function <T> require_not_empty(value: list<T>?, message: text): list<T>

Checks for empty list and throws an exception if empty.

function <K: -immutable, V> require_not_empty(value: map<K, V>?, message: text): map<K, V>

Checks for empty map and throws an exception if empty.

function <T: -immutable> require_not_empty(value: set<T>?, message: text): set<T>

Checks for empty set and throws an exception if empty.

Link copied to clipboard
(alias) function <T: -any> requireNotEmpty(value: T?, message: text): T

Checks for precence of a value and throws an exception if null.

(alias) function <T> requireNotEmpty(value: list<T>?, message: text): list<T>

Checks for empty list and throws an exception if empty.

(alias) function <K: -immutable, V> requireNotEmpty(value: map<K, V>?, message: text): map<K, V>

Checks for empty map and throws an exception if empty.

(alias) function <T: -immutable> requireNotEmpty(value: set<T>?, message: text): set<T>

Checks for empty set and throws an exception if empty.

Link copied to clipboard
(alias) function sha256(input: byte_array): byte_array

Calculates an SHA-256 hash of a byte array and returns a byte array.

Link copied to clipboard
function <T> try_call(fn: () -> T): T?

Calls a function and handles exceptions gracefully, returning null if an exception occurs.

function try_call(fn: () -> unit): boolean

Calls a function that doesn't return a value and handles exceptions gracefully.

function <T> try_call(fn: () -> T, default: T): T

Calls a function and handles exceptions gracefully, providing a fallback value if an exception occurs.

Link copied to clipboard
(alias) function verify_signature(data_hash: byte_array, pubkey: byte_array, signature: byte_array): boolean

Verifies a signature against a message and public key.